package com.ruoyi.vote.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

import java.util.List;

/**
 * 结果信息对象 result
 * 
 * @author ruoyi
 * @date 2022-10-05
 */
public class Result extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 投票结果id */
    private Long id;

    /** 用户名 */
    @Excel(name = "用户名")
    private String username;

    /** 投票id */
    @Excel(name = "投票id")
    private Long voteId;

    private List<ResultOption> options;

    public List<ResultOption> getOption() {
        return options;
    }

    public void setOption(List<ResultOption> options) {
        this.options = options;
    }

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setUsername(String username) 
    {
        this.username = username;
    }

    public String getUsername() 
    {
        return username;
    }
    public void setVoteId(Long voteId) 
    {
        this.voteId = voteId;
    }

    public Long getVoteId() 
    {
        return voteId;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("username", getUsername())
            .append("voteId", getVoteId())
            .toString();
    }
}
